<h2>活动分类 &middot;&nbsp; &middot;&nbsp; &middot;&nbsp; &middot;&nbsp; &middot;&nbsp; &middot;&nbsp;</h2>
<ul>
  <% Event.categories.each_with_index do |cat,i| -%>
    <li><%= link_to "#{cat}(#{(tmp = categories_count.find{|c| c.category == i}) ? tmp.count : 0})", :controller => '/dizhen/events', :action => 'category', :cat => i %></li>
  <% end -%>
</ul>